// 导入模块
const Mock = require('mockjs');
const { random } = require('../utils');
// 准备数据
const data = [];
for (let i = 1; i <= 8; i++) {
  data.push(
    Mock.mock({
      id: '@id',
      uname: '@ctitle(2,4)',
      type: ['密保', '短信', '扫码', '令牌'][random(0, 3)],
      area: '@province@city',
      login_time: '@datetime',
      last_login_time: '@datetime'
    })
  );
}

export default Mock.mock({
  meta: {
    state: 200,
    msg: '操作成功'
  },
  data
});
